﻿using System;
using System.Data;
using System.Collections.Generic;
using ASER.BusinessLogic.BaseBusinessLogic;
using ASER.DataAccess.Security;
using ASER.DataEntity.Security;

namespace ASER.BusinessLogic.Security
{
    public class LoginBusiness : BaseBusinessLogic<LoginDataAccess>
    {
        public List<SysMenuEntity> GetMenus(ref SysOperatorEntity user)
        {
            return DataAccess.GetMenus(ref  user);
        }

        public bool VerificationUser(string userCode, string password)
        {
            return DataAccess.VerificationUser(userCode, password);
        }

        public SysOperatorEntity GetUserData(string userCode)
        {
            return DataAccess.GetUserData(userCode);
        }

        public List<SysMenuEntity> GetUserPermits(string userCode)
        {
            return DataAccess.GetUserPermits(userCode);
        }

        public List<DeptartmentEntity> GetDepts()
        {
            return DataAccess.GetDepts();
        }

        public List<SysOperatorEntity> GetUsers(string DeptNo)
        {
            return DataAccess.GetOperators(DeptNo);
        }
    }
}
